<div id="pageInfo" data-title="我的订单"></div>
<link rel="stylesheet" href="{skin:style/mui.css}">
<script type="text/javascript" src="{theme:javascript/mui.js}"></script>

<script type="text/javascript">

mui.init();

</script>
<style>
body{
	background: #EFEFF4;
}
.header_so_btn{
	display: none;
}



.item{
	margin-bottom: 0.2rem;
} 

.desc{
	display: flex;	
	
}

.viewport{
	background: #EFEFF4;
}

.desc div{
	width: 25%;
	height: 0.6rem;
	align-items:baseline ;
	font: 0.13rem/0.6rem "微软雅黑";
	text-align: center;
}

.desc div:nth-of-type(1) img{
	width: 100%;
	height: 0.6rem;
}

.desc div:nth-of-type(2){
	width: 50%;
	border-left: 2px solid #f5f5f5;
	border-right: 2px solid #f5f5f5;
}

.desc div:nth-of-type(2) span{
	display:inline-block;
	white-space:nowrap;
	text-overflow:ellipsis;
	overflow: hidden;
	width: 100%;
	height: 0.4rem;
	
}

/*中间的标题*/
/*
.desc img{
	margin-left:0.2rem;
	width: 0.5rem;
	height: 0.5rem;
	border: 1px solid red;
}
.desc span:nth-of-type(1){
	margin-left: 0.4rem;
	width: 1rem;
	height:0.5rem;
	border: 1px solid red;
	display: inline-block;
}

.desc span:nth-of-type(2){
	margin-right: 0.2rem;
	float: right;
	margin-top: 0.14rem;	
}

*/

a{
	color:black;
}

/*页脚*/
.sfoot a{
	display: block;
	width: 100%;
	color:blue;
	
}


</style>
<section class="user_order">
	{set:$user_id = $this->user['user_id']}
    {set:$queryOrderList = Api::run('getOrderList',$user_id)}
    {set:$orderList = $queryOrderList->find()}
    
    <!-- 
    {foreach:items = $orderList key=$k item=$v}
    	
    	{foreach:items = $v key=$k1 item=$v1}
    		key:{$k1}---value:{$v1}<br/>
    	{/foreach}
    {/foreach}
     -->
    {if:$orderList}
    <!-- 
	<ul class="user_list">
		{foreach:items = $orderList}
        <li>
			<i class="icon-chevron-right"></i>
			<a href="{url:/ucenter/order_detail/id/$item[id]}">订单号：{$item['order_no']}</a>
			
		</li>
        {/foreach}
	</ul>
	{$queryOrderList->getPageBar()} -->
	
	{foreach:items = $orderList}
		
		{set:$order_id=$item['id']} 
		{foreach:items=Api::run('getOrderGoodsListByGoodsid',array('#order_id#',$order_id)) item=$good} {set:$good_info = JSON::decode($good['goods_array'])}
			<div class="mui-card item">
				<!--页眉，放置标题-->
				<div class="mui-card-header">
					{query:name = seller where= id eq $item[seller_id] item = $sl }
						<p>{$sl['store_name']}</p>
					{/query}
					<!-- <p>{$item['order_no']}</p> -->
				</div>
				<!--内容区-->
				<div class="mui-card-content desc">
					<div>
						<img alt="商品图片" src="{url:/pic/thumb/img/$good[img]}">
					</div>
					<div>
						<span>{$good_info['name']}</span>
					</div>
					<div>
						<span>￥{$good['goods_price']}</span>
					</div>
				</div>
				<!--页脚，放置补充信息或支持的操作-->
				<div class="mui-card-footer sfoot">
					<a href="{url:/ucenter/order_detail/id/$item[id]}">查看订单</a>
					<span>></span>
				</div>
			</div>
		{/foreach}
	{/foreach}
	


	
	{else:}
    <div class="nodata">当前暂无数据</div>
    {/if}
    
    
</section>
<script>
$(function(){
	//hideNav()
})
</script>
